<template>
  <div>
    <h5>高德开放地图定位</h5>
    <el-cascader :options="list.districts.name">点击显示地区</el-cascader>
    <el-button @click="mapFn">确定</el-button>
  </div>
</template>

<script>
// 引入接口
import { mapdate } from '@/api/map'
export default {
  data() {
    return {
      list: [],
      mapdata: {
        key: '09e6c733cef9812b4882ac219a45631c', // 请求服务权限标识
        keywords: '中国',
        subdistrict: '1'
      }
    }
  },
  methods: {
    async mapFn() {
      //   发送请求
      const res = await mapdate(this.mapdata)
      this.list.push(res)
    }
  }
}
</script>

<style>

</style>
